#ifndef _OCCIHANDLER_HPP
#define _OCCIHANDLER_HPP

#include "datacollection.hpp"
#include "occipool.hpp"
#include "ftpprofiles.hpp"
#include "exception"
#include <boost/date_time/posix_time/posix_time.hpp>

using namespace boost::posix_time;
using namespace com_oocl_monitor::domain;
using namespace com_oocl_monitor::system;
namespace com_oocl_monitor {
	namespace service {
		class OcciService {
		public:
			explicit OcciService(OcciPool *);
			~OcciService();
			DataCollection *perform(const Profile, const ptime startTime, const ptime endTime);
		private:
			vector<string> split(const string& str) const;
			OcciPool *_pool;
		};
		class DbException :public std::exception {
		public:
			DbException() {}
			virtual const char* what() const throw() {
				return "DB Error";
			}
		};
	}
}


#endif
